# Contributor: Kay Thomas <kaythomas@pm.me>
# Maintainer: Kay Thomas <kaythomas@pm.me>
pkgname=cadence
pkgver=0.9.1
pkgrel=2
pkgdesc="Collection of tools useful for audio production"
url="https://kx.studio/Applications:Cadence"
# py3-qt5 not packaged on armhf
arch="all !armhf"
license="GPL-2.0-or-later"
depends="
	jack-dbus
	jack_capture
	a2jmidid
	py3-qt5
	py3-dbus
	"
makedepends="
	qt5-qtbase-dev
	"
source="https://github.com/falkTX/Cadence/archive/v$pkgver/cadence-$pkgver.tar.gz
	fix-QPainterPath.patch
	"
options="!check" # No testsuite
builddir="$srcdir/Cadence-$pkgver"

build() {
	make
}

package() {
	make install PREFIX=/usr DESTDIR="$pkgdir"

	# Taken from AUR:
	# Removing claudia, as its runtime dependency ladish (dead) depends on
	# flowcanvas (dead)
	rm -rfv "$pkgdir/usr/bin/claudia"* \
			"$pkgdir/usr/share/applications/claudia"* \
			"$pkgdir/usr/share/$pkgname/"{icons,src}/{,ui_}claudia* \
			"$pkgdir/usr/share/icons/hicolor/"{128x128,16x16,256x256,48x48,scalable}/apps/claudia*
}

sha512sums="
daa9df947f0198522172451ec3d2a0e138de5245d4fa849c89ae17fc141388467bdb2e5b1ed191d1db372f4d1c02a8f1c32458c20b893d413af8fdce72ee9219  cadence-0.9.1.tar.gz
07cf8055f89b5a75ab817896f4ec68e8b1e21cf3a8f7a4f13cd1ed9a9ef1a669be624201daeacf6d13e7ee6f922b16ef650d402640710a971cd05e87b6b92389  fix-QPainterPath.patch
"
